package bsk;


import java.math.BigInteger;
import komunikaty.Card;
import komunikaty.*;

public class CardNS {
    
    public static BigInteger[] getKandString(Object lista){
        Kandydaci[] objKand = (Kandydaci[]) lista;
        BigInteger[] str = new BigInteger[objKand.length];
        for (int i = 0; i < str.length; i++) {
            str[i] = objKand[i].getPesel();
        }
        return str;
    }
    
    //generuje n kart. candidateList - lista kandydatow w wyborach
    public static Card[] genCards(BigInteger[] candidateList, int n) {
        Card[] ret = new Card[n];
        for (int i = 0; i < n; ++i) {
            ret[i] = new Card(candidateList);
        }
        return ret;
    }
}

